package com.yuhong.reggie.service;

import com.yuhong.reggie.entity.Category;
import com.yuhong.reggie.entity.Page;

import java.util.List;

public interface CategoryService {

    /**
     *
     * @param category
     * @return
     */
    boolean save(Category category);

    Page<Category> findByPage(Integer page,Integer pageSize);

    //删除
    boolean delete(Long id);

    /**
     *修改功能
     * @param category
     * @return
     */
    boolean update(Category category);

    /**
     *
     * @return
     */
    List<Category> findAll();

    /**
     * 根据类型查询类别的数据
     * @param type
     * @return
     */
    List<Category> findAllByType(Integer type);
}
